﻿@model dynamic
@{
	ViewBag.Title = "Validate";
	Layout = "~/Views/Shared/_Layout.cshtml";
}
@using (Html.BeginForm("ReValidate", "UserMgr"))
{

	//WebCommit.Common.Entitys.UserEntity userInfo = Session["LoginUser"] as WebCommit.Common.Entitys.UserEntity;
	string valStatus = Request["ValidateStatus"];
	string userId = Request["UserID"];
	string email = Request["Email"];
	<script type="text/javascript">
		function ShowMailBox() {
			$("#Div_MailBox").css("display", "block");
		}
	</script>
	<h2>
		Validate</h2>
	<div>
		@Html.Hidden("UserId", userId)
		@Html.Hidden("Email", email)
		
		@if (valStatus == "RegSucess")
  {
			<span>注册成功！请<a target="_blank" href="http://mail.@email.Split('@')[1]">点击这里</a>登录邮箱完成注册验证。<br />
			</span>
  }
  else if (valStatus == "NeedValidate")
  {
			<span>您还没有通过邮件验证，请<a target="_blank" href="http://mail.@email.Split('@')[1]">点击这里</a>登录邮箱验证。<br />
			</span>
  }
  else if (valStatus == "Resend")
  { 
			<span>已经发送了验证邮件，请<a target="_blank" href="http://mail.@email.Split('@')[1]">点击这里</a>登录邮箱验证。<br />
			</span>
	
  }
		@if (!string.IsNullOrEmpty(valStatus))
  {
			<span>没有收到邮件？<a href="javascript:ShowMailBox()">点击这里</a>修改邮箱<br />
			</span>
			<div id="Div_MailBox" style="display: none;">@Html.TextBox("NewEmail", email)<br />
				<input type="submit" value="重新验证" /></div>
  }

  
	</div>
	
}